package com.example.demo.dao;

import com.example.demo.entity.ClassroomEntity;
import com.example.demo.entity.ClassroomTypeEntity;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface ClassroomtypeDao {

    /**
     * 通过ID查询单条数据
     */
    public ClassroomTypeEntity queryClassroomtypeById(Integer ctid);

    /**
     * 通过实体作为筛选条件查询
     */
    public List<ClassroomTypeEntity> queryClassroomtypeAll();

    /**
     * 新增数据
     */
    public int insertClassroomtype(ClassroomTypeEntity classroomtype);

    /**
     * 修改数据
     */
    public int updateClassroomtype(ClassroomTypeEntity classroomtype);

    /**
     * 通过主键删除数据
     */
    public int deleteByIdClassroomtype(Integer ctid);

    //根据选择的楼栋id查询有此楼下有多少教室类型
    public List<ClassroomTypeEntity> selectClassTypeByBuilding(Integer bid);
}